﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SimpleData.ObjectModel;

namespace SimpleData.Storage.Common
{
	/// <summary>
	/// Representa a coluna com a chave que representa o documento
	/// </summary>
	public class DataObjectColumnKey : DataObjectColumn
	{
		private static readonly FieldName KeyFieldName = new FieldName( "oid" );

		public DataObjectColumnKey( DocumentToken token )
			: this( null, token )
		{ }

		public DataObjectColumnKey( SchemaName schema, DocumentToken token )
			: base( DataObjectColumnKey.KeyFieldName, null )
		{
			this.Schema = schema;
			this.Key = token;
		}

		public SchemaName Schema
		{
			get;
			private set;
		}

		public DocumentToken Key
		{
			get;
			private set;
		}
	}
}
